package com.wit.locker.service;

import com.wit.locker.domain.ChargeScheme;
import com.wit.locker.domain.Location;
import com.wit.locker.repository.ChargeSchemeRepository;
import com.wit.locker.repository.LocationRepository;
import org.springframework.beans.factory.annotation.Autowired;
import org.springframework.stereotype.Service;

import java.util.List;

@Service
public class TestService {

    @Autowired
    private LocationRepository locationRepository;

    @Autowired
    private ChargeSchemeRepository chargeSchemeRepository;


    public List<Location> getLocation() {

        return locationRepository.findAll();
    }

    public List<ChargeScheme> getChargeScheme() {
        List<ChargeScheme> all = chargeSchemeRepository.findAll();
        return all;
    }

}
